﻿@{
    var proName = ViewBag.ProName;
    var number = ViewBag.Number;
    Layout = "~/Views/Shared/_InfoPage.cshtml";
}

<section class="content" style="overflow-x: scroll">
    <div class="box box-solid" style="width: 1500px;">
        <!-- /.box-header -->
        <div class="box-body">
            <div class="row">
                @if (!string.IsNullOrEmpty(proName) && !string.IsNullOrEmpty(number))
                {
                    <div style="margin-left: 25px;">
                        <span id="historyBack" class="btn btn-primary submitbtn">返回</span>
                        <span class="btn btn-primary submitbtn" id="printBack" onclick="printBack()" style="margin-left: 25px; display: inline-block">打印背面</span>
                    </div>
                    <div id="queryDlgBack" style="width: 1480px; margin-left: 25px; margin-top: 30px;">
                        <table class="" cellspacing="0" cellpadding="0" width="1480" align="center" border="1" style="font-size: 18px;">
                            <tbody>
                                <tr style="text-align: center; height: 37px;">
                                    <td colspan="20">生产部首件确认记录</td>
                                </tr>
                                <tr style="text-align: center; height: 37px;">
                                    <td colspan="1">产品名</td>
                                    <td colspan="6">@proName</td>
                                    <td colspan="2">加工单号</td>
                                    <td colspan="2">@number</td>
                                    <td colspan="1">操作员</td>
                                    <td colspan="2"></td>
                                    <td colspan="1">加工日期</td>
                                    <td colspan="1"></td>
                                    <td colspan="1">检验员</td>
                                    <td colspan="3">12</td>
                                </tr>
                                <tr style="text-align: center; ">
                                    <td rowspan="2">序号</td>
                                    <td colspan="8" style="height: 12px;">尺寸-mm</td>
                                    <td rowspan="2">颜色</td>
                                    <td rowspan="2">内容</td>
                                    <td rowspan="2">边距</td>
                                    <td rowspan="2">跳距</td>
                                    <td rowspan="2">出卷方向</td>
                                    <td rowspan="2">撕裂线</td>
                                    <td rowspan="2">底纸</td>
                                    <td rowspan="2">检验时间</td>
                                    <td colspan="2" style="height: 12px;">结果判定</td>
                                    <td rowspan="2">备注</td>
                                </tr>
                                <tr style="text-align: center; ">
                                    <td>标准1</td>
                                    <td>测量值1</td>
                                    <td>标准2</td>
                                    <td>测量值2</td>
                                    <td>标准3</td>
                                    <td>测量值3</td>
                                    <td>标准4</td>
                                    <td>测量值4</td>
                                    <td>合格</td>
                                    <td>不合格</td>
                                </tr>
                                <tr style="text-align: center; height: 37px;">
                                    <td>1首检</td>
                                    <td></td>
                                    <td></td>
                                    <td></td>
                                    <td></td>
                                    <td></td>
                                    <td></td>
                                    <td></td>
                                    <td></td>
                                    <td></td>
                                    <td></td>
                                    <td></td>
                                    <td></td>
                                    <td></td>
                                    <td></td>
                                    <td></td>
                                    <td></td>
                                    <td></td>
                                    <td></td>
                                    <td></td>
                                </tr>

                                <tr style="text-align: center; height: 40px;">
                                    <td colspan="20"></td>
                                </tr>

                                <tr style="text-align: center; height: 37px;">
                                    <td colspan="20">质检部首件确认记录</td>
                                </tr>
                                <tr style="text-align: center; height: 37px;">
                                    <td colspan="1">产品名</td>
                                    <td colspan="6">@proName</td>
                                    <td colspan="2">加工单号</td>
                                    <td colspan="2">@number</td>
                                    <td colspan="1">操作员</td>
                                    <td colspan="2"></td>
                                    <td colspan="1">加工日期</td>
                                    <td colspan="1"></td>
                                    <td colspan="1">检验员</td>
                                    <td colspan="3">12</td>
                                </tr>
                                <tr style="text-align: center; ">
                                    <td rowspan="2">序号</td>
                                    <td colspan="8" style="height: 12px;">尺寸-mm</td>
                                    <td rowspan="2">颜色</td>
                                    <td rowspan="2">内容</td>
                                    <td rowspan="2">边距</td>
                                    <td rowspan="2">跳距</td>
                                    <td rowspan="2">出卷方向</td>
                                    <td rowspan="2">撕裂线</td>
                                    <td rowspan="2">底纸</td>
                                    <td rowspan="2">检验时间</td>
                                    <td colspan="2" style="height: 12px;">结果判定</td>
                                    <td rowspan="2">备注</td>
                                </tr>
                                <tr style="text-align: center;">
                                    <td>标准1</td>
                                    <td>测量值1</td>
                                    <td>标准2</td>
                                    <td>测量值2</td>
                                    <td>标准3</td>
                                    <td>测量值3</td>
                                    <td>标准4</td>
                                    <td>测量值4</td>
                                    <td>合格</td>
                                    <td>不合格</td>
                                </tr>
                                @for (int i = 0; i < 3; i++)
                                {
                                    var tempName = "1首检";
                                    if (i == 1)
                                    {
                                        tempName = "2巡检";
                                    }
                                    if (i == 2)
                                    {
                                        tempName = "3巡检";
                                    }
                                    <tr style="text-align: center; height: 37px;">
                                        <td>@tempName</td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                    </tr>
                                }

                                <tr style="text-align: center; height: 40px;">
                                    <td colspan="20"></td>
                                </tr>

                                <tr style="text-align: center; height: 37px;">
                                    <td colspan="20">成品检验记录表</td>
                                </tr>
                                <tr style="text-align: center;">
                                    <td rowspan="2">检验日期</td>
                                    <td rowspan="2">检验员</td>
                                    <td rowspan="2">加工单号</td>
                                    <td rowspan="2" colspan="6">产品名称</td>
                                    <td rowspan="2">生产数(pcs)</td>
                                    <td rowspan="2">检验数(pcs)</td>
                                    <td colspan="6" style="height: 12px;">不良统计</td>
                                    <td colspan="2" style="height: 12px;">检验结论</td>
                                    <td rowspan="2">不良处理</td>
                                </tr>
                                <tr style="text-align: center;">
                                    <td colspan="2">不良原因1</td>
                                    <td colspan="2">不良数量1</td>
                                    <td>不良原因2</td>
                                    <td>不良数量2</td>
                                    <td>合格</td>
                                    <td>不合格</td>
                                </tr>
                                @for (int i = 0; i < 4; i++)
                                {
                                    var tempName = "";
                                    if (i == 0)
                                    {
                                        tempName = proName;
                                    }
                                    <tr style="text-align: center; height: 40px;">
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td colspan="5">@tempName</td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td colspan="2"></td>
                                        <td colspan="2"></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                        <td></td>
                                    </tr>
                                }
                            </tbody>
                        </table>
                    </div>
                }
            </div>
        </div>
    </div>
</section>

@section Scripts {
    <script src="~/Scripts/jquery.jqprint-0.3.js"></script>
    <script>
        $("#historyBack").click(function () {
            window.history.go(-1);  //返回上一页
            //window.history.back();  //返回上一页
        });
        function printBack() {
            $('#queryDlgBack').jqprint();
        }
    </script>
}
